home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Xenosoft 2
/
Xenosoft 2 (Game collection)(1994).iso
/
bioforge
/
script
/
ai_main.scp
< prev
next >
Wrap
Text File
|
1994-12-01
|
5KB
|
230 lines
{ MONSTER_MOVE _ATK_RANGE
P ~Çü
P ~Çé
P ~Çâ
P ~Çä
~Çé = @ÇÖ
~Çâ = @Ç┤
~Çä = @Çò
@Ç¢ ( ENEMY )
~Çâ = ~Çâ + @Ç┤
~Çä = ~Çä - ~Çâ
I ( ~Çé IN -12,12 ) THEN
{
I ( ~Çä <= ~ÇÇ ) THEN // ATTACK
~Çü = 0
E I ( ~Çä < 150 ) THEN // < 1.5 METERS THEN WALK
~Çü = 8
E
~Çü = 10; // > 1.5 METERS THEN RUN
}
E I ( ~Çé > 0 ) THEN // OPPONENT TO THE LEFT
{
I ( ~Çä < 150 ) THEN // < 1.5 METERS THEN
{
~Çü = 4 // TURN LEFT
}
E
{
~Çü = 4 // TURN LEFT
}
}
E // OPPONENT TO THE RIGHT
{
I ( ~Çä < 150 ) THEN // < 1.5 METERS
{
~Çü = 6 // TURN RIGHT
}
E
{
~Çü = 6 // TURN RIGHT
}
}
é ~Çü
}
{ READY_MONSTER_TAUNT // DO NOT RUN IF A.I. IF OFF!
:LOOP
â
I @Çô ("atk_stand") != $Ç╝ THEN
J #Çé
}
{ SLUR_ENEMY_SPEECH( _HANDLE )
P ~Çü
P ~Çé
~Çü = @Çà ( 3, 5 )
~Çé = @Çà ( 3, 5 )
:TOP
I @Çû ( ~ÇÇ ) THEN
{
( ~ÇÇ , -1000 )
â
}
E
é
L #Çä ~Çü
:MID
I @Çû ( ~ÇÇ ) THEN
â
E
é
L #Çà ~Çé
:LAST
I @Çû ( ~ÇÇ ) THEN
{
( ~ÇÇ , 1000 )
â
}
E
é
L #Çå ~Çü
}
{ PAUSE_FOR_SUBTITLE
:WAIT_FOR_SUBTITLE
â
I ( @Çó ( ^ïÜ ) == $Ç╝ ) THEN
J #Çê
}
// PUT IT HERE BECAUSE ITS USED ON SEVERAL LEVELS. - LRG
{ MECHO_FIRE
// MECHO WILL FIRE A LASER FROM HIS LIMB NAMED 'GUN'
Ü ( 0,0,8, 1 )
@Ç╣ BOLTBLU GUN 10 225 (0,0,0)
}
// GUARDS NO LONGER TRY TO MOVE THEIR MOUTHS TO SPEAK -KLD
//{ GRD_SPEAK _DURATION
// APPLY CURFIG DRAWONLY FACE PICTURE 10
// WAIT _DURATION SECONDS
//}
// FOLLOWING ARE LISTED THE POSSIBLE DECALS GUARD CAN HAVE APPLIED
// GRD0PIC.FLC = PICTURE (THIS IS THE FLIC CONTAINING ALL DECALS)
// (ORIGINAL TXM MUST BE REDRAWN BEFORE DECAL UNLESS NOTED) (RESTORE) (FISTS)
// _DMG FLAGS: 2-6 DAMAGE 17 SPEAK/GROWL
//
// TEXTURE TXM FRAME _DMG DECAL
// NAME # FLAG
// HAND RIGHT SIDE LHAND 1 FIST (REPLACE ORIG TXM)
// HAND RIGHT FRONT RHAN1 2 FIST (REPLACE ORIG TXM)
// HAND LEFT SIDE RHAN 3 FIST (REPLACE ORIG TXM)
// HAND LEFT FRONT FLHAN 4 FIST (REPLACE ORIG TXM)
// CHEST CHEST 5 2 DAM CHEST A (ONLY 1 OF A,B,OR C)
// CHEST CHEST 6 3 DAM CHEST B
// CHEST CHEST 7 4 DAM CHEST C
// BACK BACK 8 5 DAM BACK
// FLEGS FLEGS 9 6 DAM LEGS
// FACE FACE 10 17 SPEAK
{ GRD_WOUNDS
P ~ÇÇ
P ~Çü
P ~Çé
P ~Çâ
P ~Çä
P ~Çà
P ~Çå
P ~Çç
~Çâ = .ÇéÇà
~Çü = .ÇéÇä
~ÇÇ = .ÇéÇÇ
~Çà = @Ç» ( ~Çü , 2, 6 );
I ~Çà > 3 THEN
~Çà = 3
~Çç = ( ~Çâ - ~ÇÇ )
~Çä = ( ~Çç / 25 )
I ~Çä > 3 THEN
~Çä = 3
I ~Çä < 1 THEN
~Çä = 0
I ( ~Çà < ~Çä ) THEN
{
:TOP
~Çå = @Çà ( 1, 3 )
N ~Çå
{
U 1
I ( @ÇÅ ( ~Çü , 2 ) || @ÇÅ ( ~Çü , 3 ) ) || @ÇÅ ( ~Çü , 4 ) THEN )
J #Çï
E
{
~Çé = @Çà ( 5, 7)
w CURFIG DRAWONLY CHEST PICTURE ~Çé GRD
a ( ~Çü , ~Çé )
}
X ÇÇ
U 2
I @ÇÅ ( ~Çü , 5 ) THEN
J #Çï
E
{
w CURFIG DRAWONLY BACK PICTURE 8 GRD
a ( ~Çü , 5 )
}
X ÇÇ
U 3
I @ÇÅ ( ~Çü , 6 ) THEN
J #Çï
E
{
w CURFIG DRAWONLY FLEGS PICTURE 9 GRD
a ( ~Çü , 6 )
}
X ÇÇ
}
}
}
{ GRD_ENTER_COMBAT
M ENTER_COMBAT
w CURFIG CLEAR LHAND PICTURE 1 GRD
w CURFIG CLEAR RHAN1 PICTURE 2 GRD
w CURFIG CLEAR RHAN PICTURE 3 GRD
w CURFIG CLEAR FLHAN PICTURE 4 GRD
}
{ GRD_LEAVE_COMBAT
w CURFIG RESTORE LHAND X GRD
w CURFIG RESTORE RHAN1 X GRD
w CURFIG RESTORE RHAN X GRD
w CURFIG RESTORE FLHAN X GRD
}
{ TURN_WHILE_FIRING
:KEEP_TURNING
â
T @ÇÖ ()
I @Çô (FIRE_GUN) THEN J #ÇÅ
}
//$ 26 - version number